<script lang="ts" setup>
import { get, post, Message, loadFile } from '@/utils'
const props = defineProps<{ src: string }>()
const visible = ref(false)
</script>
<template>
  <div class="buttons">
    <a-button type="primary" v-if="$props.src" @click="visible = true">查看</a-button>
    <span v-else>-</span>
    <a-modal title="查看视频" v-model:visible="visible" @cancel="visible = false" :footer="false">
      <video :src="props.src" controls style="width: 100%" />
    </a-modal>
  </div>
</template>
<style lang="less" scoped></style>
